<template>
  <div>
    <div class="top_1">
      <div class="left_box">
        <span>早上好, 季天意! </span>
        <el-button type="" link style="color: #999;"> 本月 </el-button>
      </div>
      <div class="right_box" style="color: #888;font-size: 13px;">
        今天是2024年3月7日 农历正月廿七 星期四 天气晴 气温15°
      </div>
    </div>
    <div class="tag_box">
      <div class="tag">
        <div class="l_tag">
          <span>新增客户 (人) </span>
          <div class="num_box">
            <span style="font-size: 23px; line-height: 23px">128</span>
            <span style="font-size: 13px; line-height: 19px">+4.2%</span>
          </div>
        </div>
        <div class="r_tag">
          <img src="./assets/customer.svg" alt="" />
        </div>
      </div>

      <div class="tag">
        <div class="l_tag">
          <span>新增销售 (单) </span>
          <div class="num_box">
            <span style="font-size: 23px; line-height: 23px">128</span>
            <span style="font-size: 13px; line-height: 19px">+4.2%</span>
          </div>
        </div>
        <div class="r_tag">
          <img src="./assets/customer.svg" alt="" />
        </div>
      </div>

      <div class="tag">
        <div class="l_tag">
          <span>销售金额 (元) </span>
          <div class="num_box">
            <span style="font-size: 23px; line-height: 23px">128</span>
            <span style="font-size: 13px; line-height: 19px">+4.2%</span>
          </div>
        </div>
        <div class="r_tag">
          <img src="./assets/1MdiClipboardFile.svg" alt="" />
        </div>
      </div>

      <div class="tag">
        <div class="l_tag">
          <span>销售退货 (单) </span>
          <div class="num_box">
            <span style="font-size: 23px; line-height: 23px">128</span>
            <span style="font-size: 13px; line-height: 19px">+4.2%</span>
          </div>
        </div>
        <div class="r_tag">
          <img src="./assets/2MdiStadium.svg" alt="" />
        </div>
      </div>

      <div class="tag">
        <div class="l_tag">
          <span>销售退货金额 (元) </span>
          <div class="num_box">
            <span style="font-size: 23px; line-height: 23px">128</span>
            <span style="font-size: 13px; line-height: 19px">+4.2%</span>
          </div>
        </div>
        <div class="r_tag">
          <img src="./assets/3MdiCountertopOutline.svg" alt="" />
        </div>
      </div>

      <div class="tag">
        <div class="l_tag">
          <span>新增供应商 (个) </span>
          <div class="num_box">
            <span style="font-size: 23px; line-height: 23px">128</span>
            <span style="font-size: 13px; line-height: 19px">+4.2%</span>
          </div>
        </div>
        <div class="r_tag">
          <img src="./assets/4MdiFormDropdown.svg" alt="" />
        </div>
      </div>

      <div class="tag">
        <div class="l_tag">
          <span>新增采购 (单) </span>
          <div class="num_box">
            <span style="font-size: 23px; line-height: 23px">128</span>
            <span style="font-size: 13px; line-height: 19px">+4.2%</span>
          </div>
        </div>
        <div class="r_tag">
          <img
            src="./assets/5MdiMicrosoftXboxControllerBatteryAlert.svg"
            alt=""
          />
        </div>
      </div>

      <div class="tag">
        <div class="l_tag">
          <span>采购金额 (元) </span>
          <div class="num_box">
            <span style="font-size: 23px; line-height: 23px">128</span>
            <span style="font-size: 13px; line-height: 19px">+4.2%</span>
          </div>
        </div>
        <div class="r_tag">
          <img src="./assets/6MdiAccountHeart.svg" alt="" />
        </div>
      </div>

      <div class="tag">
        <div class="l_tag">
          <span>采购退货 (单) </span>
          <div class="num_box">
            <span style="font-size: 23px; line-height: 23px">128</span>
            <span style="font-size: 13px; line-height: 19px">+4.2%</span>
          </div>
        </div>
        <div class="r_tag">
          <img src="./assets/7MdiFormSelect.svg" alt="" />
        </div>
      </div>

      <div class="tag">
        <div class="l_tag">
          <span>采购退货金额 (元) </span>
          <div class="num_box">
            <span style="font-size: 23px; line-height: 23px">128</span>
            <span style="font-size: 13px; line-height: 19px">+4.2%</span>
          </div>
        </div>
        <div class="r_tag">
          <img src="./assets/9FileIconsBiml.svg" alt="" />
        </div>
      </div>
    </div>

    <centerCharts />
    <bottomCharts />
  </div>
</template>
<script lang="ts" setup>
import centerCharts from "./charts/centerCharts.vue";
import bottomCharts from "./charts/bottomCharts.vue";
</script>
<style lang="less">
.top_1 {
  display: flex;
  align-items: center;
  flex-direction: row;
  justify-content: space-between;
  margin: 20px 10px;
}

.tag_box {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;

  .tag {
    flex-basis: calc(20% - 60px); /* 减去间隔宽度，假设间隔宽度为10px */
    margin: 5px; /* 每个元素的外边距，这里假设上下左右都是5px */
    border: 1px solid #eee;
    height: 45px;
    border-radius: 5px;
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding: 20px;

    .l_tag {
      display: flex;
      flex-direction: column;

      .num_box {
        display: flex;
        flex-direction: row;
        align-items: flex-end;
        margin-top: 15px;

        span:nth-child(1) {
          color: #000;
          margin-right: 40px;
        }

        span:nth-child(2) {
          color: green;
        }
      }
    }

    .r_tag {
      width: 50px;
      height: 50px;
      border-radius: 50%;
      background-color: #eff0fe;
      display: flex;
      justify-content: center;
      align-items: center;
      cursor: pointer;

      img {
        color: #5d55ff;
      }
    }
  }
}
</style>
